//
//  MYStockAlertViewController.h
//  HZTC_YaDeArt
//
//  Created by MayerF on 17/4/17.
//  Copyright © 2017年 HZTC. All rights reserved.
//

#import <UIKit/UIKit.h>

@interface MYStockAlertModel : NSObject
@property (nonatomic, copy)NSString *model_left;
@property (nonatomic, copy)NSString *model_right;
@property (nonatomic, copy)NSString *model_placeHodler;//占位文本
@property (nonatomic, copy)NSString *model_unit;//单位
@property (nonatomic, assign)BOOL model_isShowTextField;
@end

@interface MYStockAlertTableViewCell : UITableViewCell
+ (MYStockAlertTableViewCell *)cellTableView:(UITableView *)tableView
                                   indexPath:(NSIndexPath *)indexPath
                                   cellModel:(MYStockAlertModel *)cellModel;
@end

@interface MYStockAletView : UIView
- (void)alertViewWithTitle:(NSString *)title
                   message:(NSString *)message
                      data:(NSArray<MYStockAlertModel *> *)data;
- (void)updateNewData:(NSArray<MYStockAlertModel *> *)data;
- (void)refreshCellWithIndex:(NSInteger)index;
- (void)addTextFieldDidChangedAction:(void(^)(NSInteger row, id result))changedAction;
@end

@interface MYStockAlertViewController : UIViewController
+ (instancetype)alertControllerWithTitle:(NSString *)title
                                 message:(NSString *)message
                                    data:(NSArray<MYStockAlertModel *> *)data;
- (void)addCancelAction:(void(^)(id result))cancelAction;
- (void)addOkAction:(void(^)(id result))oKAction;
- (void)addTextFieldDidChangedAction:(void(^)(NSInteger row, id result))changedAction;
- (void)updateNewData:(NSArray<MYStockAlertModel *> *)data;
- (void)refreshCellWithIndex:(NSInteger)index;
@end
